(function () {

    "use strict";

    var api = {
        fansListsUrl: '/api/user/fansLists'
    };
    sm.controller('wx-center-fansLists-controller', ['$scope', '$http', function ($scope, $http){

        var search = window.location.search;
        $scope.level = search.split('=')[1];

        $scope.userLists = {};
        $scope.total = 0;
        $http.get(api.fansListsUrl, {
            params: {
                level: $scope.level
            }
        }).success(function (res) {

            if (res.state) {
                $scope.userLists = res.data.lists;
                $scope.total = res.data.total;
            }

        });

    }]);
})();

